﻿using Sidvall.UI.Views;
using System.Windows;

namespace WebOptimizer.UI.Wpf
{
	public partial class MainWindow : Window
	{
		private void Window_Closing(object sender, System.ComponentModel.CancelEventArgs e)
		{
			ViewEventArgs viewEventArgs;

			viewEventArgs = Sidvall.UI.SystemContext.Current.ConfigurationContext.Regions.NotifyViews(ViewEventType.ApplicationClosing, Sidvall.UI.Wpf.SystemContext.Current.MainWindow);
			if (viewEventArgs.Cancel)
			{
				e.Cancel = true;
			}
		}

		public MainWindow()
		{
			InitializeComponent();

			this.Width = 800;
			this.Height = 600;
			this.Language = System.Windows.Markup.XmlLanguage.GetLanguage(System.Threading.Thread.CurrentThread.CurrentCulture.Name);
		}
	}
}
